﻿using System;
using System.Collections.Generic;
using System.Text.Json.Serialization;
using YaAppoint.Appointments.PlanPools;
using YaAppoint.Devices;

namespace YaAppoint.Appointments.Pools
{
     public class PoolDto
    {
        public Guid? Id { get; set; }

        public string? Name { get; set; }

        public int? CurrentCount { get; set; }

        public PoolType? Type { get; set; }

        public DateTime Date { get; set; }

        public string StartTimeStr { get; set; }

        public string EndTimeStr { get; set; } 

        public DateTime StartTime { get; set; }

        public DateTime EndTime { get; set; }

        [JsonIgnore]    // 从序列化中忽略
        public List<AppointmentDto>? Appointments { get; set; }

        public PlanPoolDto? PlanPool { get; set; }

        public Guid? PlanPoolId { get; set; }

        public Guid? ScheduleOverrideId { get; set; }

        public Guid DeviceId { get; set; }

        public DeviceDto Device { get; set; }

        public int MaxCount { get; set; }

        public bool AllowOverFlow { get; set; }

        public bool IsActive { get; set; }

        public int SuggestOrder { get; set; } = 0;
    }
}
